<!DOCTYPE html>
<html lang="zh">
<head>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> 
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<title>基于jQuery和GSAP的图片背景视觉差特效插件|DEMO_jQuery之家-自由分享jQuery、html5、css3的插件库</title>
	<link rel="stylesheet" type="text/css" href="css/normalize.css" /><!--CSS RESET-->
	<link rel="stylesheet" type="text/css" href="css/htmleaf-demo.css"><!--演示页面样式，使用时可以不引用-->
	<link rel="stylesheet" href="css/style.css">
    	<script src="js/app.js"></script>
</head>
<body>
	<div class="htmleaf-container">
		<header class="htmleaf-header">
			<h1>基于jQuery和GSAP的图片背景视觉差特效插件 <span>jQuery parallax background plugin based on GSAP</span></h1>
			<div class="htmleaf-links">
				<a class="htmleaf-icon icon-htmleaf-home-outline" href="http://www.htmleaf.com/" title="jQuery之家" target="_blank"><span> jQuery之家</span></a>
				<a class="htmleaf-icon icon-htmleaf-arrow-forward-outline" href="http://www.htmleaf.com/jQuery/shijuecha/201806025154.html" title="返回下载页" target="_blank"><span> 返回下载页</span></a>
			</div>
		</header>
		<section class="section-intro full-width back-img" style="background-image: url('imgs/sample-background-1.jpg')">

		    <div class="container">
		        <div class="content-wrap">
		            <h1 class="main-ttl-1">
		                Parallax background
		            </h1>
		        </div>
		    </div>
		</section>


		<section class="section-features-list">
		    <div class="container">

		        <h2 class="section-title main-ttl-2">
		            Installation
		        </h2>
		        <ul class="features-list">
		            <li>
		                <div class="content-col">
		                    <div class="main-ttl-3">Include JS</div>
		                    <div class="desc">
		                      <pre class="language-markup">
		                          <code>
		                              &lt;script src="jquery.min.js">&lt;/script>
		                              &lt;script src="parallax_background.js">&lt;/script>
		                          </code>
		                      </pre>
		                    </div>
		                </div>
		            </li>
		            <li>
		                <div class="content-col">
		                    <div class="main-ttl-3">Set HTML</div>
		                    <div class="desc">
		                        <pre class="language-markup">
		                            <code>
		                                &lt;div class="parallax-background">
		                                    &lt;div class="parallax-inner" style="background-image: url('background-image.jpg')">
		                                    &lt;/div>
		                                &lt;/div>
		                            </code>
		                        </pre>
		                    </div>
		                </div>
		            </li>
		            <li>
		                <div class="content-col">
		                    <div class="main-ttl-3">Call the plugin</div>
		                    <div class="desc">
		                      <pre class="language-javascript">
		                          <code>
		                              $('.parallax-background').parallaxBackground();
		                          </code>
		                      </pre>
		                    </div>
		                </div>
		            </li>
		        </ul>
		    </div>
		</section>

		<section class="section-features-blocks">

		    <div class="container">

		        <h2 class="section-title main-ttl-2">
		            Demo
		        </h2>

		        <ul class="features-list">

		            <li class="feature-item">
		                <div class="content-col">
		                    <div class="title main-ttl-3">
		                        Basic usage
		                    </div>
		                    <div class="desc main-p-1">
		                         <pre>
		                             <code class="language-javascript">
		                                 $('.parallax-demo-1').parallaxBackground();
		                             </code>
		                        </pre>
		                    </div>
		                </div>
		                <div class="img-col">
		                    <div class="img-wrap parallax-demo-1">
		                        <div class="parallax-inner back-img"
		                             style="background-image: url('imgs/sample-background-2.jpg')">

		                        </div>
		                    </div>
		                </div>
		            </li>

		            <li class="feature-item">
		                <div class="content-col">
		                    <div class="title main-ttl-3">
		                        Animation type - rotate
		                    </div>
		                    <div class="desc main-p-1">
		                         <pre>
		                              <code class="language-javascript">
		                                  $('.parallax-demo-2').parallaxBackground({
		                                      animation_type: 'rotate',
		                                      zoom: 50,
		                                      rotate_perspective: 500
		                                  });
		                              </code>
		                        </pre>
		                    </div>
		                </div>
		                <div class="img-col">
		                    <div class="img-wrap parallax-demo-2">
		                        <div class="parallax-inner back-img"
		                             style="background-image: url('imgs/sample-background-3.jpg')">

		                        </div>
		                    </div>
		                </div>
		            </li>

		            <li class="feature-item">
		                <div class="content-col">
		                    <div class="title main-ttl-3">
		                        Event - mouse move
		                    </div>
		                    <div class="desc main-p-1">
		                       <pre>
		                              <code class="language-javascript">
		                                  $('.parallax-demo-3').parallaxBackground({
		                                      event: 'mouse_move',
		                                      animation_type: 'shift',
		                                      animate_duration: 2
		                                  });
		                              </code>
		                        </pre>
		                    </div>
		                </div>
		                <div class="img-col hover-me">
		                    <div class="img-wrap parallax-demo-3">
		                        <div class="parallax-inner back-img"
		                             style="background-image: url('imgs/sample-background-4.jpg')">

		                        </div>
		                    </div>
		                </div>
		            </li>

		            <li class="feature-item">
		                <div class="content-col">
		                    <div class="title main-ttl-3">
		                        Event - mouse move with rotate animation
		                    </div>
		                    <div class="desc main-p-1">
		                           <pre>
		                              <code class="language-javascript">
		                                  $('.parallax-demo-4').parallaxBackground({
		                                      event: 'mouse_move',
		                                      animation_type: 'rotate',
		                                      animate_duration: 1,
		                                      zoom: 70,
		                                      rotate_perspective: 1000
		                                  });
		                              </code>
		                        </pre>
		                    </div>
		                </div>
		                <div class="img-col hover-me">
		                    <div class="img-wrap parallax-demo-4">
		                        <div class="parallax-inner back-img"
		                             style="background-image: url('imgs/sample-background-1.jpg')">

		                        </div>
		                    </div>
		                </div>
		            </li>

		            <li class="feature-item">
		                <div class="content-col">
		                    <h3 class="main-ttl-3">
		                        Alternative background type
		                    </h3>
		                    <div class="desc">
		                      <pre>
		                          <code class="language-javascript">
		                              $('.parallax-demo-5').parallaxBackground({
		                                  event: 'mouse_move',
		                                  animation_type: 'rotate',
		                                  animate_duration: 1,
		                                  zoom: 70,
		                                  rotate_perspective: 1000
		                              });
		                          </code>
		                      </pre>
		                    </div>
		                </div>
		                <div class="img-col hover-me">
		                    <div class="img-wrap parallax-demo-5">
		                        <div class="parallax-inner youtube-video youtube-video-background">
		                        </div>
		                    </div>
		                </div>
		            </li>

		        </ul>
		    </div>

		</section>
		<div class="related">
		    <h3>如果你喜欢这个插件，那么你可能也喜欢:</h3>
		    <a href="http://www.htmleaf.com/jQuery/shijuecha/201805015098.html">
			  <img src="related/1.jpg" width="300" alt="jQuery固定背景视觉滚动特效插件"/>
			  <h3>jQuery固定背景视觉滚动特效插件</h3>
			</a>
			<a href="http://www.htmleaf.com/jQuery/shijuecha/201709154741.html">
			  <img src="related/2.jpg" width="300" alt="带视觉差的网格浮动图片画廊jquery特效"/>
			  <h3>带视觉差的网格浮动图片画廊jquery特效</h3>
			</a>
		</div>
	</div>
	
</body>
</html>